<div class="largecontainer">
	<div class="row">
		<div class="col s12 m12 l12">
			<div class="col s4">

			</div>
			<div class="col s4">
				<form action="">
					<h1>GLOBAL SEARCH</h1>
				</form>
				<div class="row">
					<form [formGroup]="searchForm" novalidate (ngSubmit)="searchGlobal(searchForm.value, searchForm.valid, $event)" materialize>
						<div class="input-field col s8">
							<i class="medium material-icons prefix">language</i>
							<input id="icon_prefix" type="text" class="validate" formControlName="search_term">
							<label for="icon_prefix">Search Term</label>
						</div>
						<div class="col input-field s4 m4 l4">
							<input id="search_size" type="number" class="validate" formControlName="search_size">
							<label for="search_size" class="active">Search Size</label>
						</div>
						<div class="col s12 m12 l12">
							<button class="btn waves-effect" type="submit" [disabled]="!searchForm.valid || searchSubmitted">
								Submit
							</button>
						</div>
					</form>
				</div>
				<div class="row" *ngIf="emptyResponse">
					<p class="flow-text center-align">No results found.</p>
				</div>
			</div>
			<div class="col s4">
			</div>
		</div>
	</div>
	<div class="row gridrow">
		<div class="col s12 gridrow" *ngIf="searchResponse && !emptyResponse">
			<div class="col s12 m12 l12 maingridcontent">
				<ag-grid-angular #agGrid style="height: 100%; width: 100%" class="ag-dark" [gridOptions]="gridOptions" (selectionChanged)="onSearchChange()"
				 enableColResize enableSorting enableFilter groupHeaders>
				</ag-grid-angular>
			</div>
		</div>
	</div>
</div>

<div id="modal1" materialize="modal" [materializeParams]="[{dismissible: false}]" [materializeActions]="modalActions" class="modal bottom-sheet modal-fixed-footer">
	<div class="modal-content" *ngIf="sourceRecord">
		<div class="row">
			<div class="col s6">
				<div class="rawjson tabcontent" RenderJson [jsonObject]="sourceRecord"></div>
			</div>
			<div class="col s6">
				<app-nh-tag [tagMeta]="auditObject" [docId]="docId"></app-nh-tag>
			</div>
		</div>
	</div>
	<div class="modal-content" *ngIf="connError">
		<p class="flow-text">
			HTTP Status: {{connError.status}}, Error: {{connError.statusText}}
		</p>
	</div>
	<div class="modal-footer">
		<a class="waves-effect btn-flat ambertext" (click)="destroyModalObject()">Close</a>
	</div>
</div>